import { GET_MUSIC_LIST } from '../actioins/actionsTypes';

const initState = {
  list: []
};

const setMusicList = (state, action)=>{
  return { ...state, list: action.obj.list };
};


const musicListReducer = (state = initState, action) => {
    switch(action.type) {
        case GET_MUSIC_LIST: 
          return setMusicList(state, action);
        default: return state;
    }
};

export default musicListReducer;
